﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Configuration;
using ZLDC.Common.Estate;

namespace ZLDC.Estate.AM
{
    public partial class CustomerAlertList : _PageBase
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack) 
            {
                StartTime.Value = DateTime.Today.ToString("yyyy-MM-dd");
                EndTime.Value = DateTime.Today.ToString("yyyy-MM-dd");

                AddDeptTree();
            }
        }
        private void AddDeptTree()
        {
            string sTopDept = this.info.m_sDeptID;//默认取表中第一行为最上层部门
            string deptid_list = CacheUtility.Cache_GetAllChildDept(this.info.m_sDeptID); 
           
            //sTopDept = ConfigurationSettings.AppSettings["SalesDepartment"].ToString().Trim();//最上层部门

            ZLDC.Topo.BLL.Estate.DeptTree zdt = new ZLDC.Topo.BLL.Estate.DeptTree(sTopDept, deptid_list);
            ltlDeptTree.Text = zdt.GetZlhqDept();
        }
    }
}
